package com.fowo.api.sys.model;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Schema(description = "用于请求一个新的序列号, group 与 objectName 只使用一个值，都提供时只会使用 group")
@Data
@AllArgsConstructor
@NoArgsConstructor
public class NewSerialRequest {

    public NewSerialRequest(String group, String objectName) {
        this(group, objectName, 1);
    }

    @Schema(description = "序列号组名")
    private String group;

    @Schema(description = "序列号关联对象名")
    private String objectName;

    @Schema(description = "需要的序列号数量，只有 SysSerialService.getNewSerials 才支持此参数")
    private int count;
}
